﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Core.IRepository;
using System.Data.Entity;

namespace Repositories
{
    public class UnitOfWork : IUnitOfWork
    {
        public DbContext Context;

        public UnitOfWork(DbContext Context)
        {
            this.Context = Context;
        }

        public bool Commit()
        {            
            return Context.SaveChanges() > 0;
        }
    }
}
